This page last changed on Nov 16, 2005 by rossmason.
The Mule TCK is a set of abstract testcases that test the common functionality of a component within the Mule framework. Using the Mule TCK is beneficial for the following reasons -
- Components tested with a tck testcase ensures that the common behaviour of the component is compatible with the Mule framework.
- Using a tck testcase allows the developer to concentrate on writing tests for specific behaviour of their component.
- Where testing of a method in the UMO API cannot be tested by the tck testcase, the testcase provides an abtract method for the test, ensuring the developer tests all areas of the component.
- The TCK provides a default test model that is a simple set of test classes. The developer doesn't need to worry about writing new test classes for their testcases each time.
- The TCK abstract testcases use JUnit TestCase so they are compatible with other testcases
The following describes the supplied testcases and where to use them.
Testing Component |
Description |
AbstractMuleTestCase |
This is not so much a TCK testcase, but a helper testcase providing methods for creating test and mock object types, such as
- MuleProviderDescriptor
- MuleEvent
- MuleSession
- MuleDescriptor
|
It's a good idea to extend this testcase when testing mule components.|
AbstractProxyPoolTestCase |
Mule uses a ProxyPool implementation to pool Mule proxies. There is an implementations provided; commons-pool. If you want to write your own this TCK testcase will test the default behaviour is compatible with the Mule framework. |
AbstractConnectorTestCase |
This testcase is used to test the common behaviour of a UMOConnector. This tests dispaching and sending events using mock objects. Further test cases are required to test the actual behaviour of the Connector. |
AbstractMessageAdapterTestCase |
This testcase provide tests for all the standard methods defined in the UMOMessageAdapter interface. It's usually enough to just extend this test case without writing any further tests. |
AbstractMessageReceiverTestCase |
This testcase is used to test the common behaviour of a UMOMessageReceiver. This tests receiving events using mock objects. Further test cases are required to test the actual behaviour of the MessageReceiver. |
AbstractComponentResolverTestCase |
This testcase is used to test implementations of UMOComponentResolver and UMOContainerContext, which are used to resolve object from external object containers. Mule currently supports String and PicoContainer |
AbstractEntryPointResolverTestCase |
This testcase is used to test implementations of UMOEntryPointResolver. These are used to resolve the entry point method on an object to invoke when an event is received for it. Mule comes with a couple of implementatios suitable for many scenarios. |
AbstractTransformerTestCase |
This testcase is used to test any transformers that extend AbstractTransformer. This transformer allows the developer to specify two transformers; one for converting from a particular object and one for converting it back. |
Fruit Test Model |
The fruit test model provides a set of simple objects that interact in a common way to provide an object model to test with. It can be found in the org.mule.tck.testmodels.fruit. |
|